﻿<cfparam name="ApplicationName" default="DYD">
<cfparam name="dsn1" default="lawnscoop">
<cfset file_version = "D:\Inetpub\denveryarddogversion.txt" >
<cfsetting enablecfoutputonly="true">
<cflogin>
    <cfif IsDefined('form.email_address')>
        <cfif form.email_address eq "brian@CFDeveloper.com" OR form.email_address eq "ewersc@denveryarddog.com">
            <cfset roles = "user,admin">
        <cfelse>
            <cfset roles = "user">
        </cfif>
        <cfloginuser name = "#form.email_address#" password = "1234" roles = "#roles#"/>
    <cfelse>
        <cfinclude template="loginform.cfm">
        <cfabort>
	</cfif>   
</cflogin>
<cfset actions = "Orders,Customers,Products,History">
<cfset site_phy_base = ListGetAt(cgi.CF_TEMPLATE_PATH,1,"\")&"\"&ListGetAt(cgi.CF_TEMPLATE_PATH,2,"\")&"\"&ListGetAt(cgi.CF_TEMPLATE_PATH,3,"\")&"\"&ListGetAt(cgi.CF_TEMPLATE_PATH,4,"\")&"\">
		<cfoutput>
			<!DOCTYPE html>
			<html lang="en">
			
			<head>
				<meta charset="utf-8">
				<title>#ApplicationName# | ADMIN</title>
				<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js"></script>
			</head>
			<body>
			<table width="100%">
				<tr>
					<cfif ListLen(CGI.SCRIPT_NAME,"/") IS 3>
						<td align="center"><a href="https://www.denveryarddog.com/admin/">Home</a></td>
					</cfif>
					<cfloop list="#actions#" index="this_action">
						<td align="center" <cfif ListLen(CGI.SCRIPT_NAME,"/") IS 3><cfif ListGetAt(CGI.SCRIPT_NAME,2,"/") IS this_action>bgcolor="##F0F0F0"</cfif></cfif>><cfif DirectoryExists(evaluate('site_phy_base&this_action'))><a href="https://www.denveryarddog.com/admin/#this_action#"></cfif>#this_action#</a></td>
					</cfloop>
				</tr>
			</table>
		</cfoutput>